package hospital.serviceImpl;

import java.util.List;

import hospital.dao.FinancialDao;
import hospital.model.EmpInfoModel;
import hospital.model.RecordDetailModel;
import hospital.service.FinancialService;

public class FinancialServiceImpl implements FinancialService {

	private FinancialDao financialDao;

	@Override
	public List<EmpInfoModel> getDocResult(long userId, String firstname, String lastname) {
		return financialDao.selectGetDocResult(userId, firstname, lastname);
	}

	public FinancialDao getFinancialDao() {
		return financialDao;
	}

	public void setFinancialDao(FinancialDao financialDao) {
		this.financialDao = financialDao;
	}

	@Override
	public List<RecordDetailModel> getRecordDetailList(long docId) {
		return financialDao.selectGetRecordDetailList(docId);
	}

	@Override
	public List<RecordDetailModel> searchRecord(long docId, long patientId, long recordTimeStart, long recordTimeEnd) {
		return financialDao.selectSearchRecord(docId, patientId, recordTimeStart, recordTimeEnd);
	}

	@Override
	public String checkPassword() {
		return financialDao.selectCheckPassword();
	}

	@Override
	public boolean changePassword(String password) {
		return financialDao.updateChangePassword(password);
	}

}
